<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class home extends CI_Controller {
	public function __construct(){
		parent::__construct();
		$this->load->helper(array('html','url'));
		$this->load->library('user_agent');
	}
	
	public function index()
	{			
		if ($this->agent->is_mobile())
		{
			// $data['doctype'] = doctype('xhtml1-trans');
			// $data['meta_charset'] = meta('Content-type','text/html;charset=utf-8','equiv');
			// $data['link'] = link_tag('css/wap.css');
			// $data['jquery'] = '<script src="'.base_url().'script/jquery.js"></script>';
			// 
			// 		    $this->load->view('wap/index',$data);
			
			header("Location: /ewap");
		}
		else
		{
			// $data['doctype'] = doctype('xhtml1-trans');
			// $data['meta_charset'] = meta('Content-type','text/html;charset=utf-8','equiv');
			// $data['link'] = link_tag('css/web.css');
			// $data['jquery'] = '<script src="'.base_url().'script/jquery.js"></script>';
			// 
			// 		    $this->load->view('web/index',$data);
			
			header("Location: /eweb");
		}
	}
}



/* End of file wap.php */
/* Location: ./application/controllers/web.php */